package com.itheima.cloud.user.client;

import com.itheima.cloud.pojo.Order;
import com.itheima.cloud.user.client.fallback.OrderFallback;
import org.springframework.cloud.openfeign.FeignClient;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.PathVariable;

import java.util.List;

/**
 * @Description:
 * @Version: V1.0
 */
@FeignClient(name = "order-server", fallback = OrderFallback.class)
public interface OrderClient {


    @GetMapping("order/findOrderByUserId/{username}")
    public List<Order> findOrder(@PathVariable("username") String username);

}
